<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <script src="../lib/jquery-1.10.2.min.js"></script>
    <script src="../dist/tinyselect.js"></script>
    <link rel="stylesheet" type="text/css" href="../dist/tinyselect.css" />
    <link rel="stylesheet" type="text/css" href="misc/css/example.css" />
    <link rel="stylesheet" type="text/css" href="../lib/codemirror/codemirror.css" />
    <script src="../lib/codemirror/codemirror.js"></script>
    <script src="../lib/codemirror/mode/javascript/javascript.js"></script>
    <script src="../lib/codemirror/mode/css/css.js"></script>
    <script src="misc/js/source.js"></script>
</head>

<body>
    <div class="tinyselectcontext-container">
        <div id="tinyselectcontext" class="multiple"></div>
    </div>
    <script>
        $.getJSON('misc/data/data.json').then(function (data) {
            var ts = tinyselect('#tinyselectcontext', {
                item: {
                    data: data
                },
                result: {
                    multi: true
                }
            });
            ts.on('ready', function () {
                ts.value([2, 6, 8], true);
            });
        });
    </script>
</body>

</html>